package com.zzjson.jvm.heap;

import com.zzjson.jvm.Person;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.List;

/**
 * <p>****************************************************************************</p>
 * <p><b>Copyright © 2010-2019 shuncom team All Rights Reserved<b></p>
 * <ul style="margin:15px;">
 * <li>Description : com.zzjson.jvm</li>
 * <li>Version     : 1.0.0</li>
 * <li>Creation    : 2019年12月12日</li>
 * <li>@author     : zzy0_0</li>
 * </ul>
 * <p>****************************************************************************</p>
 */
@RestController
@RequestMapping()
public class HeapController {
	List<Person> list = new ArrayList<Person>();

	@GetMapping("/heap")
	public String heap() throws Exception {
		while (true) {
			list.add(new Person());
			//Thread.sleep(1);
		}
	}
}